<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui" xmlns:a4j="http://richfaces.org/a4j">

<h:head>
	<title>add flight to the packets</title>
</h:head>
<h:body>
	<h:form>
	
		<p:panel header="addFlight form">
			<h:panelGrid columns="3" id="regGrid1">
				<p:commandButton value="Search!" update="regGrid1" id="ajax"  
             actionListener="#{PacketBean.searchFlight()}"/>
             <h6>NB: after submit Search, press F5 in order to refresh the page</h6>
             </h:panelGrid>
				<h:dataTable value="#{PacketBean.arrivalFlights}" var="item">
    		<h:column>#{item}</h:column>
		</h:dataTable>
		
		<h:dataTable value="#{PacketBean.departureFlights}" var="item">
    		<h:column>#{item}</h:column>
		</h:dataTable>
		
		</p:panel>
		
		</h:form>
	<h:link outcome="/admin/index" value="HomePage" />
	<br />
</h:body>

</html>